#!/bin/bash
# yum 软件包切换为阿里云镜像源 https://developer.aliyun.com/mirror/centos/?spm=a2c6h.25603864.0.0.3aa268feT6RdBK
sudo mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup &&
  sudo touch /etc/yum.repos.d/CentOS-Base.repo &&
  sudo curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo &&
  sudo yum makecache
